import { mapState } from 'vuex';

import listCell from '@/components/mix-list-cell';
		
export default {
	components: {
		listCell
	},
	data() {
		return {
			couponCount : null
		};
	},
	computed: {
		...mapState(['hasLogin','userInfo'])
	},
	methods: {
	
		/**
		 * 统一跳转接口,拦截未登录路由
		 * navigator标签现在默认没有转场动画，所以用view
		 */
		navTo(url){
			if(!this.hasLogin){
				url = '/pages/user/login/login';
			}
			uni.navigateTo({  
				url
			})  
		}, 
	}
}